$(function(){
    var sss = $('#dowebok').fullpage({
        sectionsColor: ['#000','#000','#000','#000', '#B4EEB4', '#8968CD', '#1E90FF'],
        'navigation': true,
        'css3': true,
        'menu':true,
        'anchors': ['page1', 'page2', 'page3', 'page4','page5','page6','page7'],
        scrollingSpeed: 1000,
        'afterLoad': function(anchorLink, index) {
            if (index == 1) {
                $('.navbar-fixed-top').css({"transform": "translate3d(0,0,0) scale(1.0,1.0)", "transform": "translate(0,0) scale(1.0,1.0)", "-moz-transform": "translate3d(0,0,0) scale(1.0,1.0)", "-webkit-transform": "translate3d(0,0,0) scale(1.0,1.0)", "transition": "all cubic-bezier(.86, 0, .07, 1) .9s"});
                $('#nav-hidden').css({"transform": "translate3d(0,-65px,0) scale(1.0,1.0)", "-webkit-transform": "translate3d(0,-65px,0) scale(1.0,1.0)", "transition": "all cubic-bezier(.86, 0, .05, 1.0) 1.0s", "opacity": 1});

            }else if(index==2){
                var val = 0;
                //page1执行cup图片透明渐变
                var timer = setInterval(colorLinerTwo,15);
                function colorLinerTwo(){
                    if(val <= 100){
                        $('.cuptime-02-02').css({"opacity":val});
                        $('.cuptime-02-01').css({"opacity":val});
                        $('.cuptime-02-03').css({"opacity":val});
                        //$('.cuptime-right').css({"opacity":val});
                        val++;
                    }
                    if (val > 100) {
                        clearInterval(timer);
                    }
                }
                $('.cuptime-02-04').removeClass("opacit-stop");
                $('.navbar-fixed-top').css({"transform": "translate3d(0,-160px,0) scale(1.0,1.0)", "transform": "translate(0,-160px) scale(1.0,1.0)","-moz-transform": "translate3d(0,-160px,0) scale(1.0,1.0)", "-webkit-transform": "translate3d(0,-160px,0) scale(1.0,1.0)","transition": "all cubic-bezier(.86, 0, .07, 1) .9s"});
                $('#nav-hidden').css({"transform": "translate3d(0,65px,0) scale(1.0,1.0)", "-webkit-transform": "translate3d(0,65px,0) scale(1.0,1.0)","transition": "all cubic-bezier(.86, 0, .05, 1.0) 2.0s","opacity": 1});
                $('.cuptime-02-01').css({"transform": "translate3d(-394px,0,0) scale(1.0,1.0)", "-webkit-transform": "translate3d(-394px,0,0) scale(1.0,1.0)","opacity": 1});
                $('.cuptime-02-03').css({"transform": "translate3d(394px,0,0) scale(1.0,1.0)", "-webkit-transform": "translate3d(394px,0,0) scale(1.0,1.0)","opacity": 1});
            }else{
                $('.navbar-fixed-top').css({"transform": "translate3d(0,-160px,0) scale(1.0,1.0)", "transform": "translate(0,-160px) scale(1.0,1.0)","-moz-transform": "translate3d(0,-160px,0) scale(1.0,1.0)", "-webkit-transform": "translate3d(0,-160px,0) scale(1.0,1.0)","transition": "all cubic-bezier(.86, 0, .07, 1) .9s"});
                $('#nav-hidden').css({"transform": "translate3d(0,65px,0) scale(1.0,1.0)", "-webkit-transform": "translate3d(0,65px,0) scale(1.0,1.0)","transition": "all cubic-bezier(.86, 0, .05, 1.0) 2.0s","opacity": 1});
            }
            if(index==4){
                $.fn.fullpage.setAllowScrolling(false, 'all');
            }
        },
        'onLeave':function(index,nextIndex,direction){
            if(index==1&&direction=="down"){
                //$('.cuptime-mp3').css({"transform": "translate3d(0,0,0) scale(1.0,-0.02)", "-webkit-transform": "translate3d(0,0,0) scale(1.0,-0.02)", "transition": "all cubic-bezier(.86, 0, .02, 0.6) 1.5s", "opacity": 1});
                //$(".cuptime-mp3").remove();
                $(".cuptime-mp3").css({"position": "fixed"});
                $("body").append($(".cuptime-mp3"));
                var actionIcon = 0;

                mpTime = setInterval(function () {
                    $(".mp-zn").removeClass("mp-show");
                    actionIcon++;
                    $(".mp-zn").eq(actionIcon).addClass("mp-show");
                    if (actionIcon == $(".mp-zn").length - 2) {
                        clearInterval(mpTime);
                    }
                }, 16);
                $(".cuptime-mp3").delay(0).animate({"opacity": 1}, 800, function () {
                    $(".cup-02").removeClass("cup-stop");
                    $(".cuptime-02-04").removeClass("opacit-stop");
                    $(".cup-02-icon").removeClass("opacit-stop");
                    $(".cuptime-mp3").css({"z-index": "-1"});
                });
            }
            if(nextIndex==1){
                $(".cuptime-mp3").stop().animate({"opacity": "1"}, 300);
                var actionuIcon = $(".mp-zn").length - 1;
                mpuTime = setInterval(function () {
                    $(".mp-zn").removeClass("mp-show");
                    actionuIcon--;
                    $(".mp-zn").eq(actionuIcon).addClass("mp-show");
                    console.log("返回第" + actionuIcon + "帧");
                    if (actionuIcon == 0) {
                        clearInterval(mpuTime);
                    }
                }, 16);
                $(".cuptime-mp3").css({"z-index": "899"});
                $(".cup-02").addClass("cup-stop");
                //$(".cuptime-02-04").addClass("opacit-stop");
            }
            if(index==2){
                var val = 100;
                //page2返回page1图标渐变
                var timer = setInterval(colorLinerTwo1,10);
                function colorLinerTwo1(){
                    if(val >= 0){
                        $('.cuptime-02-02').css({"opacity":0});
                        $('.cuptime-02-01').css({"opacity":0});
                        $('.cuptime-02-03').css({"opacity":0});
                        val--;
                    }
                    if (val < 0) {
                        clearInterval(timer);
                    }
                }
                $(".cuptime-02-04").addClass("opacit-stop");
                $('.cuptime-02-01').css({"transform": "translate3d(0,0,0) scale(1.0,1.0)", "-webkit-transform": "translate3d(0,0,0) scale(1.0,1.0)"});
                $('.cuptime-02-03').css({"transform": "translate3d(0,0,0) scale(1.0,1.0)", "-webkit-transform": "translate3d(0,0,0) scale(1.0,1.0)"});
            }
            if(index==3){

                //$.fn.fullpage.moveTo(2);
                //count++;
            }
        },
        'afterRender':function(){
            $('.cuptime-left').css({"transform": "translate3d(-300px,0,0) scale(1.0,1.0)", "-webkit-transform": "translate3d(-300px,0,0) scale(1.0,1.0)", "transition": "all cubic-bezier(.86, 0, .02, 0.6) 1.5s", "opacity": 1});
            $('.cuptime-right').css({"transform": "translate3d(300px,0,0) scale(1.0,1.0)", "-webkit-transform": "translate3d(300px,0,0) scale(1.0,1.0)", "transition": "all cubic-bezier(.86, 0, .02, 0.6) 1.5s", "opacity": 1});

            window.onload = function(){
                var val = 0;
                //page1执行cup图片透明渐变
                var timer = setInterval(colorLiner,20);
                //page1执行title图片透明渐变
                setTimeout(Titlerun, 1500 );
                function colorLiner(){
                    if(val < 100){
                        $('.cuptime-left').css({"opacity":val});
                        $('.cuptime-right').css({"opacity":val});
                        val++;
                    }
                    if (val > 100) {
                        clearInterval(timer);
                    }
                }
                function Titlerun(){
                    var val1 = 0;
                    var timer1 = setInterval(colorTitle,10);
                    function colorTitle(){
                        if(val1 < 100){
                            $('.cuptime-title').css({"opacity":val1/100});
                            val1++;
                        }
                        if (val1 > 100) {
                            clearInterval(timer1);
                        }
                    }
                }
            }
        },
        'navigationTooltips': ['第一屏', '第二屏', '第三平', '第四屏','第五屏','第六屏','第七屏']
    });
});
var count = 0;
function mouse(e){
    //获取鼠标滚轮参数
    var delta =e.detail ?-e.detail /3: e.wheelDelta /120;
    //根据参数判断上滚下滚来响应时间
    if(delta==-1){
        if(count==0){
            $('.cup-07-title').eq(count).removeClass('opacit-stop');
            $(".cup-img").eq(0).css({"transform": "translate3d(0,-" + 150 + "px,0)", "-webkit-transform": "translate3d(0,-" + 150 + "px,0)", "-moz-transform": "translate3d(0,-" + 150 + "px,0)", "-o-transform": "translate3d(0,-" + 150 + "px,0)"});
            $(".cup-07-tit").css({"transform": "translate3d(0,-" + 300 + "px,0)", "-webkit-transform": "translate3d(0,-" + 300 + "px,0)", "-moz-transform": "translate3d(0,-" + 300 + "px,0)", "-o-transform": "translate3d(0,-" + 300 + "px,0)"});

            count++;
            return false;
        }
        if(count==1){
            $('.cup-07-title').eq(count).removeClass('opacit-stop');
            $('.cup-07-title').eq(count-1).addClass('opacit-stop');
            $(".cup-img").eq(0).css({"transform": "translate3d(0,-" + 350 + "px,0)", "-webkit-transform": "translate3d(0,-" + 350 + "px,0)", "-moz-transform": "translate3d(0,-" + 350 + "px,0)", "-o-transform": "translate3d(0,-" + 350 + "px,0)"});
            $(".cup-img").eq(1).css({"transform": "translate3d(0,-" + 200 + "px,0)", "-webkit-transform": "translate3d(0,-" + 200 + "px,0)", "-moz-transform": "translate3d(0,-" + 200 + "px,0)", "-o-transform": "translate3d(0,-" + 200 + "px,0)"});
            count++;
            return false;
        }
        if(count==2){
            $('.cup-07-title').eq(count).removeClass('opacit-stop');
            $('.cup-07-title').eq(count-1).addClass('opacit-stop');
            $(".cup-img").eq(0).css({"transform": "translate3d(0,-" + 680 + "px,0)", "-webkit-transform": "translate3d(0,-" + 680 + "px,0)", "-moz-transform": "translate3d(0,-" + 680 + "px,0)", "-o-transform": "translate3d(0,-" + 680 + "px,0)"});
            $(".cup-img").eq(1).css({"transform": "translate3d(0,-" + 600 + "px,0)", "-webkit-transform": "translate3d(0,-" + 600 + "px,0)", "-moz-transform": "translate3d(0,-" + 600 + "px,0)", "-o-transform": "translate3d(0,-" + 600 + "px,0)"});
            $(".cup-img").eq(2).css({"transform": "translate3d(0,-" + 150 + "px,0)", "-webkit-transform": "translate3d(0,-" + 150 + "px,0)", "-moz-transform": "translate3d(0,-" + 150 + "px,0)", "-o-transform": "translate3d(0,-" + 150 + "px,0)"});
            count++;
            return false;
        }
        if(count==3){
            $('.cup-07-title').eq(count).removeClass('opacit-stop');
            $('.cup-07-title').eq(count-1).addClass('opacit-stop');
            $(".cup-img").eq(0).css({"transform": "translate3d(0,-" + 830 + "px,0)", "-webkit-transform": "translate3d(0,-" + 830 + "px,0)", "-moz-transform": "translate3d(0,-" + 830 + "px,0)", "-o-transform": "translate3d(0,-" + 830 + "px,0)"});
            $(".cup-img").eq(1).css({"transform": "translate3d(0,-" + 750 + "px,0)", "-webkit-transform": "translate3d(0,-" + 750 + "px,0)", "-moz-transform": "translate3d(0,-" + 750 + "px,0)", "-o-transform": "translate3d(0,-" + 750 + "px,0)"});
            $(".cup-img").eq(2).css({"transform": "translate3d(0,-" + 300 + "px,0)", "-webkit-transform": "translate3d(0,-" + 300 + "px,0)", "-moz-transform": "translate3d(0,-" + 300 + "px,0)", "-o-transform": "translate3d(0,-" + 300 + "px,0)"});
            $(".cup-img").eq(3).css({"transform": "translate3d(0,-" + 150 + "px,0)", "-webkit-transform": "translate3d(0,-" + 150 + "px,0)", "-moz-transform": "translate3d(0,-" + 150 + "px,0)", "-o-transform": "translate3d(0,-" + 150 + "px,0)"});
            count++;
            return false;
        }
        if(count==4){
            $('.cup-07-title').eq(count).removeClass('opacit-stop');
            $('.cup-07-title').eq(count-1).addClass('opacit-stop');
            $(".cup-img").eq(0).css({"transform": "translate3d(0,-" + 980 + "px,0)", "-webkit-transform": "translate3d(0,-" + 980 + "px,0)", "-moz-transform": "translate3d(0,-" + 980 + "px,0)", "-o-transform": "translate3d(0,-" + 980 + "px,0)"});
            $(".cup-img").eq(1).css({"transform": "translate3d(0,-" + 900 + "px,0)", "-webkit-transform": "translate3d(0,-" + 900 + "px,0)", "-moz-transform": "translate3d(0,-" + 900 + "px,0)", "-o-transform": "translate3d(0,-" + 900 + "px,0)"});
            $(".cup-img").eq(2).css({"transform": "translate3d(0,-" + 450 + "px,0)", "-webkit-transform": "translate3d(0,-" + 450 + "px,0)", "-moz-transform": "translate3d(0,-" + 450 + "px,0)", "-o-transform": "translate3d(0,-" + 450 + "px,0)"});
            $(".cup-img").eq(3).css({"transform": "translate3d(0,-" + 300 + "px,0)", "-webkit-transform": "translate3d(0,-" + 300 + "px,0)", "-moz-transform": "translate3d(0,-" + 300 + "px,0)", "-o-transform": "translate3d(0,-" + 300 + "px,0)"});
            $(".cup-img").eq(4).css({"transform": "translate3d(0,-" + 150 + "px,0)", "-webkit-transform": "translate3d(0,-" + 150 + "px,0)", "-moz-transform": "translate3d(0,-" + 150 + "px,0)", "-o-transform": "translate3d(0,-" + 150 + "px,0)"});
            count++;
            return false;
        }
        if(count==5){
            $('.cup-07-title').eq(count).removeClass('opacit-stop');
            $('.cup-07-title').eq(count-1).addClass('opacit-stop');
            $(".cup-img").eq(0).css({"transform": "translate3d(0,-" + 1130 + "px,0)", "-webkit-transform": "translate3d(0,-" + 1130 + "px,0)", "-moz-transform": "translate3d(0,-" + 1130 + "px,0)", "-o-transform": "translate3d(0,-" + 1130 + "px,0)"});
            $(".cup-img").eq(1).css({"transform": "translate3d(0,-" + 1050 + "px,0)", "-webkit-transform": "translate3d(0,-" + 1050 + "px,0)", "-moz-transform": "translate3d(0,-" + 1050 + "px,0)", "-o-transform": "translate3d(0,-" + 1050 + "px,0)"});
            $(".cup-img").eq(2).css({"transform": "translate3d(0,-" + 600 + "px,0)", "-webkit-transform": "translate3d(0,-" + 600 + "px,0)", "-moz-transform": "translate3d(0,-" + 600 + "px,0)", "-o-transform": "translate3d(0,-" + 600 + "px,0)"});
            $(".cup-img").eq(3).css({"transform": "translate3d(0,-" + 450 + "px,0)", "-webkit-transform": "translate3d(0,-" + 450 + "px,0)", "-moz-transform": "translate3d(0,-" + 450 + "px,0)", "-o-transform": "translate3d(0,-" + 450 + "px,0)"});
            $(".cup-img").eq(4).css({"transform": "translate3d(0,-" + 300 + "px,0)", "-webkit-transform": "translate3d(0,-" + 300 + "px,0)", "-moz-transform": "translate3d(0,-" + 300 + "px,0)", "-o-transform": "translate3d(0,-" + 300 + "px,0)"});
            $(".cup-img").eq(5).css({"transform": "translate3d(0,-" + 150 + "px,0) scale(0.49,0.49)", "-webkit-transform": "translate3d(0,-" + 150 + "px,0) scale(0.49,0.49)", "-moz-transform": "translate3d(0,-" + 150 + "px,0) scale(0.49,0.49)", "-o-transform": "translate3d(0,-" + 150 + "px,0) scale(0.49,0.49)"});
            count++;
            return false;
        }
        if(count==6){
            $('.cup-07-title').eq(count).removeClass('opacit-stop');
            $('.cup-07-title').eq(count-1).addClass('opacit-stop');
            $(".cup-img").eq(0).css({"transform": "translate3d(0,-" + 1280 + "px,0)", "-webkit-transform": "translate3d(0,-" + 1280 + "px,0)", "-moz-transform": "translate3d(0,-" + 1280 + "px,0)", "-o-transform": "translate3d(0,-" + 1280 + "px,0)"});
            $(".cup-img").eq(1).css({"transform": "translate3d(0,-" + 1200 + "px,0)", "-webkit-transform": "translate3d(0,-" + 1200 + "px,0)", "-moz-transform": "translate3d(0,-" + 1200 + "px,0)", "-o-transform": "translate3d(0,-" + 1200 + "px,0)"});
            $(".cup-img").eq(2).css({"transform": "translate3d(0,-" + 750 + "px,0)", "-webkit-transform": "translate3d(0,-" + 750 + "px,0)", "-moz-transform": "translate3d(0,-" + 750 + "px,0)", "-o-transform": "translate3d(0,-" + 750 + "px,0)"});
            $(".cup-img").eq(3).css({"transform": "translate3d(0,-" + 600 + "px,0)", "-webkit-transform": "translate3d(0,-" + 600 + "px,0)", "-moz-transform": "translate3d(0,-" + 600 + "px,0)", "-o-transform": "translate3d(0,-" + 600 + "px,0)"});
            $(".cup-img").eq(4).css({"transform": "translate3d(0,-" + 450 + "px,0)", "-webkit-transform": "translate3d(0,-" + 450 + "px,0)", "-moz-transform": "translate3d(0,-" + 450 + "px,0)", "-o-transform": "translate3d(0,-" + 450 + "px,0)"});
            $(".cup-img").eq(5).css({"transform": "translate3d(0,-" + 300 + "px,0) scale(0.49,0.49)", "-webkit-transform": "translate3d(0,-" + 300 + "px,0) scale(0.49,0.49)", "-moz-transform": "translate3d(0,-" + 300 + "px,0) scale(0.49,0.49)", "-o-transform": "translate3d(0,-" + 300 + "px,0) scale(0.49,0.49)"});
            $(".cup-img").eq(6).css({"transform": "translate3d(0,-" + 150 + "px,0)", "-webkit-transform": "translate3d(0,-" + 150 + "px,0)", "-moz-transform": "translate3d(0,-" + 150 + "px,0)", "-o-transform": "translate3d(0,-" + 150 + "px,0)"});
            count++;
            return false;
        }
        if(count==7){
            $('.cup-07-title').eq(count).removeClass('opacit-stop');
            $('.cup-07-title').eq(count+1).removeClass('opacit-stop');
            $('.cup-07-title').eq(count-1).addClass('opacit-stop');
            $(".cup-img").eq(0).css({"transform": "translate3d(0,-" + 1430 + "px,0)", "-webkit-transform": "translate3d(0,-" + 1430 + "px,0)", "-moz-transform": "translate3d(0,-" + 1430 + "px,0)", "-o-transform": "translate3d(0,-" + 1430 + "px,0)"});
            $(".cup-img").eq(1).css({"transform": "translate3d(0,-" + 1350 + "px,0)", "-webkit-transform": "translate3d(0,-" + 1350 + "px,0)", "-moz-transform": "translate3d(0,-" + 1350 + "px,0)", "-o-transform": "translate3d(0,-" + 1350 + "px,0)"});
            $(".cup-img").eq(2).css({"transform": "translate3d(0,-" + 1130 + "px,0)", "-webkit-transform": "translate3d(0,-" + 1130 + "px,0)", "-moz-transform": "translate3d(0,-" + 1130 + "px,0)", "-o-transform": "translate3d(0,-" + 1130 + "px,0)"});
            $(".cup-img").eq(3).css({"transform": "translate3d(0,-" + 750 + "px,0)", "-webkit-transform": "translate3d(0,-" + 750 + "px,0)", "-moz-transform": "translate3d(0,-" + 750 + "px,0)", "-o-transform": "translate3d(0,-" + 750 + "px,0)"});
            $(".cup-img").eq(4).css({"transform": "translate3d(0,-" + 600 + "px,0)", "-webkit-transform": "translate3d(0,-" + 600 + "px,0)", "-moz-transform": "translate3d(0,-" + 600 + "px,0)", "-o-transform": "translate3d(0,-" + 600 + "px,0)"});
            $(".cup-img").eq(5).css({"transform": "translate3d(0,-" + 457 + "px,0) scale(0.49,0.49)", "-webkit-transform": "translate3d(0,-" + 457 + "px,0) scale(0.49,0.49)", "-moz-transform": "translate3d(0,-" + 457 + "px,0) scale(0.49,0.49)", "-o-transform": "translate3d(0,-" + 457 + "px,0) scale(0.49,0.49)"});
            $(".cup-img").eq(6).css({"transform": "translate3d(0,-" + 300 + "px,0)", "-webkit-transform": "translate3d(0,-" + 300 + "px,0)", "-moz-transform": "translate3d(0,-" + 300 + "px,0)", "-o-transform": "translate3d(0,-" + 300 + "px,0)"});
            $(".cup-img").eq(7).css({"transform": "translate3d(0,-" + 150 + "px,0)", "-webkit-transform": "translate3d(0,-" + 150 + "px,0)", "-moz-transform": "translate3d(0,-" + 150 + "px,0)", "-o-transform": "translate3d(0,-" + 150 + "px,0)"});
            count++;
            return false;
        }
        if(count==8){
            $.fn.fullpage.setAllowScrolling(true, 'all');
            $.fn.fullpage.moveTo(5);
            return false;
        }
    }
    if(delta==1){
        if(count==0){
            count=0;
            $.fn.fullpage.setAllowScrolling(true, 'all');
            $.fn.fullpage.moveTo(3);
        }
        if(count==1){
            $('.cup-07-title').eq(count).addClass('opacit-stop');
            $('.cup-07-title').eq(count-1).addClass('opacit-stop');
            $(".cup-img").eq(0).css({"transform": "translate3d(0,0,0)", "-webkit-transform": "translate3d(0,0,0)", "-moz-transform": "translate3d(0,0,0)", "-o-transform": "translate3d(0,0,0)"});
            $(".cup-07-tit").css({"transform": "translate3d(0,0,0)", "-webkit-transform": "translate3d(0,0,0)", "-moz-transform": "translate3d(0,0,0)", "-o-transform": "translate3d(0,0,0)"});
            count--;
            return false;
        }
        if(count==2){
            $('.cup-07-title').eq(count).addClass('opacit-stop');
            $('.cup-07-title').eq(count-1).addClass('opacit-stop');
            $('.cup-07-title').eq(count-2).removeClass('opacit-stop');
            $(".cup-img").eq(0).css({"transform": "translate3d(0,-" + 150 + "px,0)", "-webkit-transform": "translate3d(0,-" + 150 + "px,0)", "-moz-transform": "translate3d(0,-" + 150 + "px,0)", "-o-transform": "translate3d(0,-" + 150 + "px,0)"});
            $(".cup-img").eq(1).css({"transform": "translate3d(0,0,0)", "-webkit-transform": "translate3d(0,0,0)", "-moz-transform": "translate3d(0,0,0)", "-o-transform": "translate3d(0,0,0)"});
            count--;
            return false;
        }
        if(count==3){
            $('.cup-07-title').eq(count).addClass('opacit-stop');
            $('.cup-07-title').eq(count-1).addClass('opacit-stop');
            $('.cup-07-title').eq(count-2).removeClass('opacit-stop');
            $(".cup-img").eq(0).css({"transform": "translate3d(0,-" + 300 + "px,0)", "-webkit-transform": "translate3d(0,-" + 300 + "px,0)", "-moz-transform": "translate3d(0,-" + 300 + "px,0)", "-o-transform": "translate3d(0,-" + 300 + "px,0)"});
            $(".cup-img").eq(1).css({"transform": "translate3d(0,-" + 150 + "px,0)", "-webkit-transform": "translate3d(0,-" + 150 + "px,0)", "-moz-transform": "translate3d(0,-" + 150 + "px,0)", "-o-transform": "translate3d(0,-" + 150 + "px,0)"});
            $(".cup-img").eq(2).css({"transform": "translate3d(0,0,0)", "-webkit-transform": "translate3d(0,0,0)", "-moz-transform": "translate3d(0,0,0)", "-o-transform": "translate3d(0,0,0)"});
            count--;
            return false;
        }
        if(count==4){
            $('.cup-07-title').eq(count).addClass('opacit-stop');
            $('.cup-07-title').eq(count-1).addClass('opacit-stop');
            $('.cup-07-title').eq(count-2).removeClass('opacit-stop');
            $(".cup-img").eq(0).css({"transform": "translate3d(0,-" + 750 + "px,0)", "-webkit-transform": "translate3d(0,-" + 750 + "px,0)", "-moz-transform": "translate3d(0,-" + 750 + "px,0)", "-o-transform": "translate3d(0,-" + 750 + "px,0)"});
            $(".cup-img").eq(1).css({"transform": "translate3d(0,-" + 600 + "px,0)", "-webkit-transform": "translate3d(0,-" + 600 + "px,0)", "-moz-transform": "translate3d(0,-" + 600 + "px,0)", "-o-transform": "translate3d(0,-" + 600 + "px,0)"});
            $(".cup-img").eq(2).css({"transform": "translate3d(0,-" + 150 + "px,0)", "-webkit-transform": "translate3d(0,-" + 150 + "px,0)", "-moz-transform": "translate3d(0,-" + 150 + "px,0)", "-o-transform": "translate3d(0,-" + 150 + "px,0)"});
            $(".cup-img").eq(3).css({"transform": "translate3d(0,0,0)", "-webkit-transform": "translate3d(0,0,0)", "-moz-transform": "translate3d(0,0,0)", "-o-transform": "translate3d(0,0,0)"});
            count--;
            return false;
        }
        if(count==5){
            $('.cup-07-title').eq(count).addClass('opacit-stop');
            $('.cup-07-title').eq(count-1).addClass('opacit-stop');
            $('.cup-07-title').eq(count-2).removeClass('opacit-stop');
            $(".cup-img").eq(0).css({"transform": "translate3d(0,-" + 900 + "px,0)", "-webkit-transform": "translate3d(0,-" + 900 + "px,0)", "-moz-transform": "translate3d(0,-" + 900 + "px,0)", "-o-transform": "translate3d(0,-" + 900 + "px,0)"});
            $(".cup-img").eq(1).css({"transform": "translate3d(0,-" + 750 + "px,0)", "-webkit-transform": "translate3d(0,-" + 750 + "px,0)", "-moz-transform": "translate3d(0,-" + 750 + "px,0)", "-o-transform": "translate3d(0,-" + 750 + "px,0)"});
            $(".cup-img").eq(2).css({"transform": "translate3d(0,-" + 300 + "px,0)", "-webkit-transform": "translate3d(0,-" + 300 + "px,0)", "-moz-transform": "translate3d(0,-" + 300 + "px,0)", "-o-transform": "translate3d(0,-" + 300 + "px,0)"});
            $(".cup-img").eq(3).css({"transform": "translate3d(0,-" + 150 + "px,0)", "-webkit-transform": "translate3d(0,-" + 150 + "px,0)", "-moz-transform": "translate3d(0,-" + 150 + "px,0)", "-o-transform": "translate3d(0,-" + 150 + "px,0)"});
            $(".cup-img").eq(4).css({"transform": "translate3d(0,0,0)", "-webkit-transform": "translate3d(0,0,0)", "-moz-transform": "translate3d(0,0,0)", "-o-transform": "translate3d(0,0,0)"});
            count--;
            return false;
        }
        if(count==6){
            $('.cup-07-title').eq(count).addClass('opacit-stop');
            $('.cup-07-title').eq(count-1).addClass('opacit-stop');
            $('.cup-07-title').eq(count-2).removeClass('opacit-stop');
            $(".cup-img").eq(0).css({"transform": "translate3d(0,-" + 750 + "px,0)", "-webkit-transform": "translate3d(0,-" + 750 + "px,0)", "-moz-transform": "translate3d(0,-" + 750 + "px,0)", "-o-transform": "translate3d(0,-" + 750 + "px,0)"});
            $(".cup-img").eq(1).css({"transform": "translate3d(0,-" + 600 + "px,0)", "-webkit-transform": "translate3d(0,-" + 600 + "px,0)", "-moz-transform": "translate3d(0,-" + 600 + "px,0)", "-o-transform": "translate3d(0,-" + 600 + "px,0)"});
            $(".cup-img").eq(2).css({"transform": "translate3d(0,-" + 450 + "px,0)", "-webkit-transform": "translate3d(0,-" + 450 + "px,0)", "-moz-transform": "translate3d(0,-" + 450 + "px,0)", "-o-transform": "translate3d(0,-" + 450 + "px,0)"});
            $(".cup-img").eq(3).css({"transform": "translate3d(0,-" + 300 + "px,0)", "-webkit-transform": "translate3d(0,-" + 300 + "px,0)", "-moz-transform": "translate3d(0,-" + 300 + "px,0)", "-o-transform": "translate3d(0,-" + 300 + "px,0)"});
            $(".cup-img").eq(4).css({"transform": "translate3d(0,-" + 150 + "px,0)", "-webkit-transform": "translate3d(0,-" + 150 + "px,0)", "-moz-transform": "translate3d(0,-" + 150 + "px,0)", "-o-transform": "translate3d(0,-" + 150 + "px,0)"});
            $(".cup-img").eq(5).css({"transform": "translate3d(0,0,0) scale(0.49,0.49)", "-webkit-transform": "translate3d(0,0,0) scale(0.49,0.49)", "-moz-transform": "translate3d(0,0,0) scale(0.49,0.49)", "-o-transform": "translate3d(0,0,0) scale(0.49,0.49)"});
            count--;
            return false;
        }
        if(count==7){
            $('.cup-07-title').eq(count).addClass('opacit-stop');
            $('.cup-07-title').eq(count-1).addClass('opacit-stop');
            $('.cup-07-title').eq(count-2).removeClass('opacit-stop');
            $(".cup-img").eq(0).css({"transform": "translate3d(0,-" + 1200 + "px,0)", "-webkit-transform": "translate3d(0,-" + 1200 + "px,0)", "-moz-transform": "translate3d(0,-" + 1200 + "px,0)", "-o-transform": "translate3d(0,-" + 1200 + "px,0)"});
            $(".cup-img").eq(1).css({"transform": "translate3d(0,-" + 750 + "px,0)", "-webkit-transform": "translate3d(0,-" + 750 + "px,0)", "-moz-transform": "translate3d(0,-" + 750 + "px,0)", "-o-transform": "translate3d(0,-" + 750 + "px,0)"});
            $(".cup-img").eq(2).css({"transform": "translate3d(0,-" + 600 + "px,0)", "-webkit-transform": "translate3d(0,-" + 600 + "px,0)", "-moz-transform": "translate3d(0,-" + 600 + "px,0)", "-o-transform": "translate3d(0,-" + 600 + "px,0)"});
            $(".cup-img").eq(3).css({"transform": "translate3d(0,-" + 450 + "px,0)", "-webkit-transform": "translate3d(0,-" + 450 + "px,0)", "-moz-transform": "translate3d(0,-" + 450 + "px,0)", "-o-transform": "translate3d(0,-" + 450 + "px,0)"});
            $(".cup-img").eq(4).css({"transform": "translate3d(0,-" + 300 + "px,0)", "-webkit-transform": "translate3d(0,-" + 300 + "px,0)", "-moz-transform": "translate3d(0,-" + 300 + "px,0)", "-o-transform": "translate3d(0,-" + 300 + "px,0)"});
            $(".cup-img").eq(5).css({"transform": "translate3d(0,-" + 150 + "px,0) scale(0.49,0.49)", "-webkit-transform": "translate3d(0,-" + 150 + "px,0) scale(0.49,0.49)", "-moz-transform": "translate3d(0,-" + 150 + "px,0) scale(0.49,0.49)", "-o-transform": "translate3d(0,-" + 150 + "px,0) scale(0.49,0.49)"});
            $(".cup-img").eq(6).css({"transform": "translate3d(0,0,0)", "-webkit-transform": "translate3d(0,0,0)", "-moz-transform": "translate3d(0,0,0)", "-o-transform": "translate3d(0,0,0)"});
            count--;
            return false;
        }
        if(count==8){
            $('.cup-07-title').eq(count).addClass('opacit-stop');
            $('.cup-07-title').eq(count-1).addClass('opacit-stop');
            $('.cup-07-title').eq(count-2).removeClass('opacit-stop');
            $(".cup-img").eq(0).css({"transform": "translate3d(0,-" + 1280 + "px,0)", "-webkit-transform": "translate3d(0,-" + 1280 + "px,0)", "-moz-transform": "translate3d(0,-" + 1280 + "px,0)", "-o-transform": "translate3d(0,-" + 1280 + "px,0)"});
            $(".cup-img").eq(1).css({"transform": "translate3d(0,-" + 1200 + "px,0)", "-webkit-transform": "translate3d(0,-" + 1200 + "px,0)", "-moz-transform": "translate3d(0,-" + 1200 + "px,0)", "-o-transform": "translate3d(0,-" + 1200 + "px,0)"});
            $(".cup-img").eq(2).css({"transform": "translate3d(0,-" + 750 + "px,0)", "-webkit-transform": "translate3d(0,-" + 750 + "px,0)", "-moz-transform": "translate3d(0,-" + 750 + "px,0)", "-o-transform": "translate3d(0,-" + 750 + "px,0)"});
            $(".cup-img").eq(3).css({"transform": "translate3d(0,-" + 600 + "px,0)", "-webkit-transform": "translate3d(0,-" + 600 + "px,0)", "-moz-transform": "translate3d(0,-" + 600 + "px,0)", "-o-transform": "translate3d(0,-" + 600 + "px,0)"});
            $(".cup-img").eq(4).css({"transform": "translate3d(0,-" + 450 + "px,0)", "-webkit-transform": "translate3d(0,-" + 450 + "px,0)", "-moz-transform": "translate3d(0,-" + 450 + "px,0)", "-o-transform": "translate3d(0,-" + 450 + "px,0)"});
            $(".cup-img").eq(5).css({"transform": "translate3d(0,-" + 307 + "px,0) scale(0.49,0.49)", "-webkit-transform": "translate3d(0,-" + 307 + "px,0) scale(0.49,0.49)", "-moz-transform": "translate3d(0,-" + 307 + "px,0) scale(0.49,0.49)", "-o-transform": "translate3d(0,-" + 307 + "px,0) scale(0.49,0.49)"});
            $(".cup-img").eq(6).css({"transform": "translate3d(0,-" + 150 + "px,0)", "-webkit-transform": "translate3d(0,-" + 150 + "px,0)", "-moz-transform": "translate3d(0,-" + 150 + "px,0)", "-o-transform": "translate3d(0,-" + 150 + "px,0)"});
            $(".cup-img").eq(7).css({"transform": "translate3d(0,0,0)", "-webkit-transform": "translate3d(0,0,0)", "-moz-transform": "translate3d(0,0,0)", "-o-transform": "translate3d(0,0,0)"});
            count--;
            return false;
        }
    }
    return false;
}